{% extends "monitor/hbase_base.html" %}
{% load extended_filter %}

{% block hbase_content %}
    <h4>SummaryMetric&nbsp;&nbsp;|&nbsp;&nbsp;<a href="/monitor/regionserver/operation/{{ regionserver.id }}">OperationMetric</a></h4>
    <h2>RegionServer: {{ regionserver.name }}</h2>
    <div class="row">
        <div class="span3">MemStoreSize(MB): {{ regionserver.memStoreSizeMB }}</div>
        <div class="span3">StorefileSize(MB): {{ regionserver.storefileSizeMB }}</div>
        <div class="span3">Read QPS: {{ regionserver.readRequestsCountPerSec }}</div>
        <div class="span3">Write QPS: {{ regionserver.writeRequestsCountPerSec }}</div>
    </div>
    <div class="row">
        <div class="span12"><h3>QPS history</h3></div>
    </div>
    <div class="row">
        <div class="span6">
            <a href="{{tsdb_url_prefix}}/#start={{start_date}}{{ tsdb_read_query|join:"" }}&yrange=[0:]&key=out%20center%20top&wxh={{12|pic_width}}x{{tsdb_read_query|pic_heigth}}" >
                <img src="{{tsdb_url_prefix}}/q?start={{start_date}}{{ tsdb_read_query|join:""}}&yrange=[0:]&key=out%20center%20top&wxh={{6|pic_width}}x{{tsdb_read_query|pic_heigth}}&png" />
            </a>
        </div>
        <div class="span6">
            <a href="{{tsdb_url_prefix}}/#start={{start_date}}{{ tsdb_write_query|join:"" }}&yrange=[0:]&key=out%20center%20top&wxh={{12|pic_width}}x{{tsdb_read_query|pic_heigth}}" >
                <img src="{{tsdb_url_prefix}}/q?start={{start_date}}{{ tsdb_write_query|join:""}}&yrange=[0:]&key=out%20center%20top&wxh={{6|pic_width}}x{{tsdb_write_query|pic_heigth}}&png" />
            </a>
        </div>
    </div>
    <div class="row">
        <div class="span12"><h3>QPS distribution on regions</h3></div>
    </div>
    <div class="row">
        <div class="span12"> {{ read_requests_dist_by_rs_chart }} </div>
    </div>
    <div class="row">
        <div class="span12"> {{ write_requests_dist_by_rs_chart }} </div>
    </div>
{% endblock %}
